[Unit]
Description=filebeat server daemon
Documentation=/opt/filebeat/filebeat --help
Wants=network-online.target
After=network-online.target

[Service]
User=root
Group=root
Restart=on-failure
Environment="BEAT_CONFIG_OPTS=-c {{ filebeat_install_path }}/{{ filebeat_link }}/filebeat.yml"
ExecStart={{ filebeat_install_path }}/{{ filebeat_link }}/filebeat $BEAT_CONFIG_OPTS

[Install]
WantedBy=multi-user.target